home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Gold Medal Software 3
/
Gold Medal Software - Volume 3 (Gold Medal) (1994).iso
/
print
/
pascii17.arj
/
PASCII17.DOC
< prev
Wrap
Text File
|
1994-03-31
|
6KB
|
144 lines
PASCII 1.7 Copyright 1993-1994 by Joohee Jeong
(Released on Mar.31, 1994)
Overview: PASCII prepares an ASCII file for printing. Supports
header/footer, pagination, file-name, time/date of printing,
time/date of file, one/two-sided printing, line numbering, left
margin (even/odd side), top margin, bottom margin, line-breaking,
FormFeed character, TAB character expansion. Removes trailing
blanks. Handles UNIX text files. ** Freeware **
What's new:
v1.5: Some bugs related to FormFeed character and header/footer
fixed.
v1.6: Removes ASCII-26 at the end of file. Minor bug fix.
Smaller executable size.
v1.7: Added an option to reverse the order of the pages in PASCII.EVN.
TAB expansion didn't work at all. Fixed.
Installation: Put the two files PASCII.EXE and PASCII.CFG in some
directory in your PATH.
Usage: pascii [options] filename
options = -1 or -2 (1 or 2 sided printing)
-num[+-] (line numbering on/off)
-c filename (configuration file)
-tab n (TAB size 1 <= n <= 16)
-header[+-] (header on/off)
-footer[+-] (footer on/off)
-headfooter[+-] (header/footer on/off)
If one-sided printing option is selected, then PASCII produces the
output file PASCII.OUT (in the current directory), which can be sent
to the printer by the DOS command:
copy pascii.out prn
If two-sided printing option is selected, then PASCII produces two
output files PASCII.EVN (for page 2,4,6,...) and PASCII.ODD (for
page 1,3,5,...), which can be sent to the printer by the DOS
commands:
copy pascii.evn prn
copy pascii.odd prn
You can have PASCII.EVN reversely ordered by setting the last entry
in PASCII.CFG 1 (i.e., "true").
It is convenient to have batch files pout.bat (peven.bat, podd.bat,
resp.) that consists of the single line "copy pascii.out prn" ("copy
pascii.evn prn", "copy pascii.odd prn", resp.) in some directory in
your PATH.
If an input file is non-ASCII, then no output is generated.
Configuration: All options are specified in a configuration file, say
PASCII.CFG, which is first searched in the current directory and
then in the directory in which PASCII.EXE resides. This
configuration file PASCII.CFG can be freely edited by any text
editor. The order of the configuration variables (i.e., options)
matters. You should not mess up the order. Blank lines are ignored.
Any text after the comment character `%' is ignored.
Following is an example of PASCII.CFG:
66 % 30 <= pageheight <= 80
80 % 30 <= pagewidth <= 90
2 % 1 or 2 sided
2 % 0 <= top margin <= 30
2 % 0 <= bottom margin <= 30
6 % 0 <= even margin <= 40
10 % 0 <= odd margin <= 40
8 % 1 <= TabSize <= 16
\page/\npages \hfill{─} \filename % even header
\filename \hfill{─} \page/\npages % odd header
\page/\npages \hfill{─} (Printed on \ptime) \filename % even footer
Last modified on \ftime \hfill{─} \page/\npages % odd footer
0 % line numbering: 1=true, 0=false
1 % use header: 1=true, 0=false
1 % use footer: 1=true, 0=false
1 % reverse PASCII.EVN: 1=true, 0=false
If one-sided printing option is selected, then the parameters for
odd pages are used for all pages, odd or even. (That is, parameters
for even pages are ignored.)
Everything except possibly the "commands" in header/footer will be
self-evident:
\page is the current page
\npages is the total number of pages
\filename is the input filename
\ptime is the date and time of printing
\ftime is the date and time of the input file
\hfill{x} inserts the characters x to fill the line. \hfill
is identical to \hfill{ }
Command line options: Some configuration options in PASCII.CFG that
need frequent change can be overridden by command line switches.
The switch -1 (-2, resp.) forces one-sided printing (two-sided
printing, resp.).
The switch -num (-num-, resp.) forces line numbering (line
no-numbering, resp.). -num+ has the same effect as -num.
The switch -tab n can be used to set the tab size to n, where
1 <= n <= 16.
The switch -header (-header-, resp.) forces to use header (not to
use header, resp.). -header+ has the same effect as -header.
The switches -footer[+-] and -headfooter[+-] should be obvious.
Moreover, the configuration file itself can be specified by the
command line switch -c: for instance,
pascii -c source.cfg somefile
processes the input file SOMEFILE using the configuration variables
in SOURCE.CFG (first searched in the current directory and then in
the directory in which PASCII.EXE resides).
Limitations:
(i) Doesn't accept multiple input files.
(ii) Doesn't process an input file if the file name is one among
PASCII.OUT, PASCII.EVN and PASCII.ODD.
(iii) FormFeed character must be either the first or the last
character of a line.
(iv) Each CarriageReturn character must be followed by a LineFeed
character.
(v) Cannot prevent line-breaking in trailing blanks.
DISCLAIMER: This software comes with absolutely no warranty. In
no event the author shall be liable for direct, indirect or con-
sequential damages, loses, costs, fees or expenses of any nature
or kind.
----------------------------------------------------------------
Joohee Jeong Author of JSpell (ASP Shareware)
Email: 73072.3651@compuserve.com Phone/Fax (510) 528-8753
Nemosoft Technologies, P.O.Box 1619, El Cerrito, CA 94530, U.S.A.